/*
 * uc_dipsw.c
 *
 *  Created on: Feb 8, 2013
 *      Author: bfakhri
 */

#include "uc_dipsw.h"
#include "gpio.h"
//Calls gpio_port_dd_get_pin_state() to return the state of the pin connected to p_switch.
int uc_dipsw_get_state(int p_switch)
{
	return !gpio_port_dd_get_pin_state(p_switch);	// Changes switch to pin 
}

//Calls gpio_port_dd_init() to initialize switches 1, 2, 3, and 4.
void uc_dipsw_init()
{
	gpio_port_dd_init();	// Initializes all relevant switches
}
